<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@taglib uri="http://www.springframework.org/tags" prefix="spring"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title></title>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<link rel="stylesheet" type="text/css"
	href="<c:url value="/static/jquery-easyui/themes/default/easyui.css"/>">
<link rel="stylesheet" type="text/css"
	href="<c:url value="/static/jquery-easyui/themes/icon.css"/>">
<script type="text/javascript"
	src="<c:url value="/static/jquery-easyui/jquery-1.6.min.js"/>"></script>
<script>
	// 种类格式
	var costTypeClass;
	$.ajax({
		async : false,
		url : "<c:url value='/cost/costTypeFormate.do'/>",
		type : "post",
		data : {
			costType : 1
		},
		success : function(data) {
			costTypeClass = data;
			if(typeof(costTypeClass)=='string'){
				costTypeClass =JSON.parse(costTypeClass);
            }
		}
	});
	//设置种类
	function formatCostType(value, row, index, field) {
		for (var i = 0; i < costTypeClass.length; i++) {
			if (value == costTypeClass[i].codeId) {
				return costTypeClass[i].costType;
			}
		}
		return "无";
	}
</script>
</head>
<body>
</body>
</html>